#include "matrix/gsl_matrix.h"
#include "ddas_results.h"

const char* DATA_FILE_NAME = "data";
const char* SCOPING_FILE_NAME = "scope";

double SLEEP_UNIT = 2.0;
int BINARY_ARRAY_SIZE = 128;

DDAS_CLIENT_RESULT_SET* result_set;

gsl_matrix* master;
gsl_matrix* independent;
gsl_vector* dependent;

int columns_used=0;
int dependent_var_count=0;
int independent_var_count=0;
int results_to_return=0;
int row_count=0;

verylong total_result_count=0;
verylong starting_value;
verylong ending_value=0;

/** 
* @author Max Rupplin
* @date 5-15-08
* 
* 'free_globals' frees memory for the globally scoped variables at the end of the program
*/ 
void free_globals()
{
	gsl_matrix_free(master);
	gsl_matrix_free(independent);
	gsl_vector_free(dependent);

	zfree( &total_result_count );
	zfree( &starting_value );
	zfree( &ending_value );
	
	delete result_set;
}